<template>
  <div>
    测试 测试 测试
    <h2>{{ state.connected }}</h2>
  </div>
</template>

<script setup>
import { socket, state } from "./utils/socket"

onMounted(() => {

  socket.on("connect", () => {
    state.connected = true;
    socket.emit('joinRoom', 33153283)
  });
  socket.on('msgToClient', (msg) => {
    const data = msg.data
    console.log(data);
  })


})

</script>

<style scoped></style>
